/*
 * @Author: lanbos 
 * @Date: 2017-12-16 16:00:15 
 * @Last Modified by: lanbos
 * @Last Modified time: 2017-12-18 13:16:44
 */

// 弹窗路由方法，不能单独执行；
import ajaxData from './ajaxData';
module.exports={
  pop_now(){
    ajaxData.activity2(this.cityCode, this.calls, data => {
      this.popInfo = data;
      console.log(data);
    });
  },
  pop_has(){
    ajaxData.status2(data=>{
      console.log(data);
      this.popInfo=data;
    })
  },
  pop_amount(){
    ajaxData.status2(data=>{
      console.log(data);
      this.popInfo=data;
    })
  },
  pop_phone1(){
    // ajaxData.status2(data=>{
    //   if(!!data.phone){
    //     this.initPop('phone2',data.phone);
    //   }
    //   this.popInfo=data;
    // })
  },
  pop_phone2(phone){
    if(phone){
      this.popInfo={
        phone
      }
      return;
    }
    ajaxData.status2(data=>{
      if(!data.phone){
        this.initPop('phone1');
      }
      this.popInfo=data;
    })
  },
  pop_close(){
    this.popInfo=null;
    this.mask=0;
    this.saving=0;
  }
}